Creating Data Sources and Connection Factory
tomee.xml is the file where all the data sources, JMS configurations are made. Any data source, which is needed by an application to run, has to be configured in this file. Cycle requires ADMINSREVERDS, ADMINSERVERSOURCEDS, ADMINSERVERSEARCHDS, ADMINSERVERREADONLYDS datasources to be created.
We need to configure the Connection Factory and Queue required for JMS setup. The following example shows the way of configuring them if the server is running locally.
Sample configuration of all the data sources which are required for Cycle to run:
Data Source
<Resource id="ADMINSERVERDS" type="javax.sql.DataSource">
jdbcDriver = oracle.jdbc.driver.OracleDriver
jdbcUrl = jdbc:oracle:thin:@<Host ip Address>:<port>:<SID>
userName = <User>
password = <Pwd>
jtaManaged = false
</Resource>
<Resource id="JMSResourceAdapter" type="ActiveMQResourceAdapter">
BrokerXmlConfig = broker:(tcp://localhost:61616)
Serverurl = tcp://localhost:61616
DataSource = ADMINSERVERDS
</Resource>
<Resource id="IntakeConnectionFactory" type="jakarta.jms.ConnectionFactory">
resourceAdapter = JMSResourceAdapter
</Resource>
<Container id="JmsMdbContainer" ctype="MESSAGE">
ResourceAdapter = JMSResourceAdapter
</Container>
<Resource id="DIQueue" type="jakarta.jms.Queue"/>
Note: The localhost of the above settings need to be changed to the respective server host where Cycle is running.